﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;
/**
 * 播放音乐 音效
 **/
public class AudioManager : MonoBehaviour
{
    public static AudioManager instance { get;private set; }

    private AudioSource audioS;

    // Start is called before the first frame update
    void Start()
    {
        instance = this;
        audioS = GetComponent<AudioSource>();
    }

    // Update is called once per frame
    void Update()
    {
        
    }
    /*
     *播放制定的音效 
     */
    public void AudioPlay(AudioClip clip) {
        audioS.PlayOneShot(clip);
    }
}
